ostree.git
9 years ago2016.7-1
Simon McVittie [Thu, 28 Jul 2016 06:41:02 +0000 (07:41 +0100)]
2016.7-1

9 years agod/control: mention Flatpak, not its former name xdg-app
Simon McVittie [Sun, 17 Jul 2016 08:33:43 +0000 (09:33 +0100)]
d/control: mention Flatpak, not its former name xdg-app

9 years agoupdate symbols file for new ABI
Simon McVittie [Sun, 17 Jul 2016 07:56:32 +0000 (08:56 +0100)]
update symbols file for new ABI

9 years agobuild-depend on libsystemd (unconditionally, because this package is Linux-specific...
Simon McVittie [Sun, 17 Jul 2016 07:47:41 +0000 (08:47 +0100)]
build-depend on libsystemd (unconditionally, because this package is Linux-specific already)

9 years agoAdd patch from upstream to make sure we use the built binaries for build-time testing
Simon McVittie [Sat, 16 Jul 2016 20:16:11 +0000 (21:16 +0100)]
Add patch from upstream to make sure we use the built binaries for build-time testing

9 years agoNew upstream version
Simon McVittie [Sat, 16 Jul 2016 20:08:02 +0000 (21:08 +0100)]
New upstream version

- drop all patches, applied upstream

9 years agoMerge tag 'upstream/2016.7' into debian/master
Simon McVittie [Sat, 16 Jul 2016 20:06:36 +0000 (21:06 +0100)]
Merge tag 'upstream/2016.7' into debian/master

Upstream version 2016.7

9 years agoImported Upstream version 2016.7
Simon McVittie [Sat, 16 Jul 2016 20:06:34 +0000 (21:06 +0100)]
Imported Upstream version 2016.7

9 years agoRelease 2016.7
Colin Walters [Fri, 8 Jul 2016 19:29:11 +0000 (15:29 -0400)]
Release 2016.7

Closes: #386
Approved by: jlebon

9 years agofetcher: Remove unused GTask structure member
Colin Walters [Fri, 8 Jul 2016 17:17:33 +0000 (13:17 -0400)]
fetcher: Remove unused GTask structure member

Spotted by mbarnes.

Closes: #383
Approved by: mbarnes

9 years agofetcher: Clear all data for session in session thread
Colin Walters [Fri, 8 Jul 2016 14:15:47 +0000 (10:15 -0400)]
fetcher: Clear all data for session in session thread

Conceptually the session thread owns the session, so let's clear out
everything predictably there, rather than sometimes having it happen
on the main thread.

Also, this moves up clearing the pending/outstanding queues *before*
we unreference the session, since conceptually they need to reference
it as well.

Based on a patch from: Matthew Barnes <mbarnes@redhat.com>

Closes: #383
Approved by: mbarnes

9 years agofetcher: Hold a ref to main context for lifetime of thread
Colin Walters [Fri, 8 Jul 2016 14:01:47 +0000 (10:01 -0400)]
fetcher: Hold a ref to main context for lifetime of thread

I don't think this fixes the bug I was seeing, but it makes me more
comfortable to know we have a strong ref to the main context across
the thread lifetime, and we only unset the default right before
we go away.

If something in `thread_closure_unref()` used
`g_main_context_get_thread_default()` for example it'd be wrong
before.

Closes: #383
Approved by: mbarnes

9 years agotests: Add some test coverage of repeated pulls w/HTTP 500s
Colin Walters [Thu, 7 Jul 2016 21:39:07 +0000 (17:39 -0400)]
tests: Add some test coverage of repeated pulls w/HTTP 500s

Systems like pulp may want to keep retrying in a loop if the server
throws a (hopefully transient) 500, and we need test coverage of
handling these errors versus our existing 404 and 206 coverage.

Closes: #383
Approved by: mbarnes

9 years agotests/libtest.sh: Print non-matching file on failure
Colin Walters [Thu, 7 Jul 2016 21:36:08 +0000 (17:36 -0400)]
tests/libtest.sh: Print non-matching file on failure

We clean up the temporary directory on failure, which means it's hard
to know *why* a regex didn't match.  Print it when we hit an error.

Closes: #383
Approved by: mbarnes

9 years agopull: Free fetch_data by default
Mathnerd314 [Sat, 18 Jun 2016 16:23:12 +0000 (10:23 -0600)]
pull: Free fetch_data by default

This should fix the memory leaks in #352

This is a subset of the changes, the other part is in my pull code rewrite

Closes: #382
Approved by: cgwalters

9 years agoSwitch sense of check in debian/test.sh so we really ignore test failures on mipsel...
Simon McVittie [Wed, 6 Jul 2016 14:23:38 +0000 (15:23 +0100)]
Switch sense of check in debian/test.sh so we really ignore test failures on mipsel, and not on !mipsel.

9 years ago2016.6-3
Simon McVittie [Wed, 6 Jul 2016 09:17:56 +0000 (10:17 +0100)]
2016.6-3

9 years agostatic-delta-core.c: squash unused var warning
Jonathan Lebon [Mon, 4 Jul 2016 16:49:49 +0000 (12:49 -0400)]
static-delta-core.c: squash unused var warning

Closes: #379
Approved by: cgwalters

9 years agolibostree: Fix build failure with glib 2.42
Bastien Nocera [Mon, 4 Jul 2016 10:31:27 +0000 (10:31 +0000)]
libostree: Fix build failure with glib 2.42

G_DEFINE_AUTOPTR_CLEANUP_FUNC is a new function in GLib 2.44, but
libglnx contains a backported version of it. A few source files were
however using G_DEFINE_AUTOPTR_CLEANUP_FUNC either without including
libglnx.h, or without including it early enough.

This fix is similar to the one in commit d368624.

Closes #376

Closes: #377
Approved by: smcv

9 years agodocs: Add a section on Docker
Colin Walters [Thu, 30 Jun 2016 19:29:28 +0000 (15:29 -0400)]
docs: Add a section on Docker

This could have a lot more obviously, but just laying down my thoughts
as a starting point.

Closes: #374
Approved by: jlebon

9 years agodelta: Add --if-not-exists option
Colin Walters [Fri, 1 Jul 2016 18:39:49 +0000 (14:39 -0400)]
delta: Add --if-not-exists option

I often want to have "idempotent" systems that iterate to a known
state.  If after generating a commit, the system is interrupted, I'd
like the next run to still generate a delta.  But we don't want to
regenerate if one exists, hence this option.

Closes: #375
Approved by: jlebon

9 years agoIgnore build-time test failures on mipsel
Simon McVittie [Mon, 4 Jul 2016 09:06:55 +0000 (10:06 +0100)]
Ignore build-time test failures on mipsel

"ostree pull" intermittently fails with a bus error on at least some
mipsel CPUs, and applying gdb to the resulting core dump does not produce
any useful information. Debugging help would be appreciated. (Mitigates:
#827473)

9 years ago2016.6-2
Simon McVittie [Tue, 28 Jun 2016 08:30:01 +0000 (09:30 +0100)]
2016.6-2

9 years agoUse the GitHub repository as the Homepage and Source
Simon McVittie [Tue, 28 Jun 2016 08:29:50 +0000 (09:29 +0100)]
Use the GitHub repository as the Homepage and Source

The GNOME wiki page is less frequently updated.

9 years agoAdd patch from upstream fixing FTBFS on host machines without root= in /proc/cmdline
Simon McVittie [Tue, 28 Jun 2016 08:27:09 +0000 (09:27 +0100)]
Add patch from upstream fixing FTBFS on host machines without root= in /proc/cmdline

The reproducible builds armhf workers are one example.

9 years agobuild: Override systemd unit directory for distcheck
Dan Nicholson [Mon, 27 Jun 2016 20:06:23 +0000 (13:06 -0700)]
build: Override systemd unit directory for distcheck

distcheck tests that all the files are installed under $prefix. That
doesn't work with the systemd unit directory since the path comes from
pkg-config. Override the setting to be under $prefix in that case.

Closes: #372
Approved by: cgwalters

9 years agotests: Improve check for /proc/cmdline kargs
Dan Nicholson [Fri, 13 May 2016 19:53:01 +0000 (12:53 -0700)]
tests: Improve check for /proc/cmdline kargs

On some systems there may be no root= argument, so the tests for
appending /proc/cmdline arguments will fail. Instead, loop over each of
the arguments in the host's /proc/cmdline and test that they're in the
constructed config file. That will actually test if ostree added all of
the system's /proc/cmdline args correctly. The regex isn't perfect here,
but it's probably good enough for this test.

Closes: #372
Approved by: cgwalters

9 years agotests: Remove extra $CMD_PREFIX from test-auto-summary.sh
Dan Nicholson [Fri, 13 May 2016 18:38:50 +0000 (11:38 -0700)]
tests: Remove extra $CMD_PREFIX from test-auto-summary.sh

$OSTREE already has $CMD_PREFIX in it, so adding it again causes you to
call env twice with LD_PRELOAD.

Closes: #372
Approved by: cgwalters

9 years agobuild: Distribute libglnx and bsdiff Makefile templates
Dan Nicholson [Fri, 13 May 2016 18:01:29 +0000 (11:01 -0700)]
build: Distribute libglnx and bsdiff Makefile templates

In order to re-run autogen.sh from the tarball, the libglnx and bsdiff
Makefile templates need to be provided.

Closes: #372
Approved by: cgwalters

9 years agotests: Ensure mutable deployments from libostreetest
Dan Nicholson [Fri, 13 May 2016 17:22:02 +0000 (10:22 -0700)]
tests: Ensure mutable deployments from libostreetest

When creating sysroots with libostreetest, we don't get the benefit of
the OSTREE_SYSROOT_DEBUG setting in libtest.sh. That means we'll get
immutable deployments that can't be easily cleaned up.

Ensure the environment variable is set before creating new sysroots. It
would be nice to set the debug flags directly, but that's private API
that isn't currently pulled into libostreetest.

Closes: #372
Approved by: cgwalters

9 years agotests: Remove gpg verification files from EXTRA_DIST
Dan Nicholson [Fri, 13 May 2016 13:47:09 +0000 (06:47 -0700)]
tests: Remove gpg verification files from EXTRA_DIST

Follow on from 70a11189. These files are already disted.

Closes: #372
Approved by: cgwalters

9 years agoostree admin switch: fix short summary
Jonathan Lebon [Mon, 27 Jun 2016 17:59:22 +0000 (13:59 -0400)]
ostree admin switch: fix short summary

Closes: #371
Approved by: cgwalters

9 years agocheckout: Add an option to require hardlinks
Colin Walters [Sun, 26 Jun 2016 14:25:03 +0000 (10:25 -0400)]
checkout: Add an option to require hardlinks

I've seen a few people hit this and wonder why checkouts are slow/take
space.  Really, ensuring this happens is the *point* of OSTree.
Physical copies should be a last resort fallback for very unusual
situations (one of those is rpm-ostree checking out the db since
librpm doesn't know how to read from libostree).

Even I hit the fact that `/var` is a mountpoint disallowing hardlinks
with `/ostree` once and was confused.  =)

Add this to the rofiles-fuse test case because it creates a mount
point.

Closes: #368
Approved by: jlebon

9 years agorofiles-fuse: Do allow fchmod/fchown on directories
Colin Walters [Sun, 26 Jun 2016 14:23:56 +0000 (10:23 -0400)]
rofiles-fuse: Do allow fchmod/fchown on directories

The program is called ro*files* and ostree creates physical
copies of directories, so changing them is fine.

I hit this when trying to do a copy checkout onto an rofiles-fuse
mount.

Closes: #368
Approved by: jlebon

9 years agotests: fail the build if symlinking tests/ostree fails
Simon McVittie [Sun, 26 Jun 2016 12:57:13 +0000 (13:57 +0100)]
tests: fail the build if symlinking tests/ostree fails

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #367
Approved by: cgwalters

9 years agotests: use our own generated libtool, not the one in $PATH
Simon McVittie [Sun, 26 Jun 2016 12:56:05 +0000 (13:56 +0100)]
tests: use our own generated libtool, not the one in $PATH

libtoolize creates a version of libtool for the right architecture
in $(top_builddir), which is guaranteed to be present, and is
guaranteed to match what we are compiling (even during
cross-compilation).

Packaging systems sometimes separate /usr/bin/libtool, which is
specific to one architecture, from the libtool development files
such as libtoolize and ltmain.sh, which are architecture-independent.
For example, in Debian, libtool_*_all.deb contains the files necessary
to libtoolize a package and is depended on by the dh-autoreconf package,
but libtool-bin_*_amd64.deb (or whatever architecture) contains
/usr/bin/libtool and is not normally necessary to depend on.

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #367
Approved by: cgwalters

9 years agoentry_pathname_test_helper: these tests need extended attributes
Simon McVittie [Sun, 26 Jun 2016 13:26:37 +0000 (14:26 +0100)]
entry_pathname_test_helper: these tests need extended attributes

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #366
Approved by: cgwalters

9 years ago2016.6-1
Simon McVittie [Sun, 26 Jun 2016 19:01:24 +0000 (20:01 +0100)]
2016.6-1

9 years agod/control: ostree no longer needs its Suggests on dracut
Simon McVittie [Sun, 26 Jun 2016 18:51:04 +0000 (19:51 +0100)]
d/control: ostree no longer needs its Suggests on dracut

A stronger dependency on dracut will be needed in the ostree-boot package
when the boot integration is reinstated (see #824650).

9 years agoClose #827473 in changelog
Simon McVittie [Sun, 26 Jun 2016 18:37:55 +0000 (19:37 +0100)]
Close #827473 in changelog

9 years agoSkip more tests if /var/tmp doesn't support extended attributes
Simon McVittie [Sun, 26 Jun 2016 13:29:31 +0000 (14:29 +0100)]
Skip more tests if /var/tmp doesn't support extended attributes

9 years agoBuild-depend on cpio, for the libarchive test
Simon McVittie [Sun, 26 Jun 2016 13:21:34 +0000 (14:21 +0100)]
Build-depend on cpio, for the libarchive test

9 years agoadd patches to ensure that the build-time tests act on the copy of ostree that we...
Simon McVittie [Sun, 26 Jun 2016 12:58:19 +0000 (13:58 +0100)]
add patches to ensure that the build-time tests act on the copy of ostree that we just built

9 years agoupdate symbols file
Simon McVittie [Sun, 26 Jun 2016 12:07:42 +0000 (13:07 +0100)]
update symbols file

9 years agod/p/pull-Correctly-handle-repo-parent_repo-when-applying-stat.patch: apply patch...
Simon McVittie [Sun, 26 Jun 2016 11:32:22 +0000 (12:32 +0100)]
d/p/pull-Correctly-handle-repo-parent_repo-when-applying-stat.patch: apply patch from upstream to fix a bug that flatpak currently works around

9 years agod/p/libostree.sym-Fix-test-symbols.patch: apply patch from upstream to fix a build...
Simon McVittie [Sun, 26 Jun 2016 11:27:19 +0000 (12:27 +0100)]
d/p/libostree.sym-Fix-test-symbols.patch: apply patch from upstream to fix a build-time test

9 years agoNew upstream release
Simon McVittie [Sun, 26 Jun 2016 11:20:39 +0000 (12:20 +0100)]
New upstream release

  - drop all patches, included upstream

9 years agod/gbp.conf: configure to merge upstream tags into upstream/latest (add https://github...
Simon McVittie [Sun, 26 Jun 2016 11:16:58 +0000 (12:16 +0100)]
d/gbp.conf: configure to merge upstream tags into upstream/latest (add https://github.com/ostreedev/ostree as a remote)

9 years agod/gbp.conf: configure to use upstream/latest for upstream imports
Simon McVittie [Sun, 26 Jun 2016 11:16:05 +0000 (12:16 +0100)]
d/gbp.conf: configure to use upstream/latest for upstream imports

9 years agoMerge branch 'upstream/latest' into debian/master
Simon McVittie [Sun, 26 Jun 2016 11:15:11 +0000 (12:15 +0100)]
Merge branch 'upstream/latest' into debian/master

9 years agoMerge tag 'v2016.6' into upstream/latest
Simon McVittie [Sun, 26 Jun 2016 11:13:49 +0000 (12:13 +0100)]
Merge tag 'v2016.6' into upstream/latest

Release 2016.6

9 years agoMerge tag 'upstream/2016.6' into debian/master
Simon McVittie [Sun, 26 Jun 2016 11:12:28 +0000 (12:12 +0100)]
Merge tag 'upstream/2016.6' into debian/master

Upstream version 2016.6

9 years agoImported Upstream version 2016.6
Simon McVittie [Sun, 26 Jun 2016 11:12:26 +0000 (12:12 +0100)]
Imported Upstream version 2016.6

9 years agod/watch: fetch releases from GitHub instead of GNOME
Simon McVittie [Sun, 26 Jun 2016 11:12:09 +0000 (12:12 +0100)]
d/watch: fetch releases from GitHub instead of GNOME

9 years agobuild-sys: Make libostree-1.so depend on the symbol file
Colin Walters [Fri, 24 Jun 2016 13:35:21 +0000 (09:35 -0400)]
build-sys: Make libostree-1.so depend on the symbol file

Otherwise one changing it doesn't cause a symbol to be exported.

Closes: #365
Approved by: jlebon

9 years agotests: Test partial commits for local remotes
Alexander Larsson [Tue, 7 Jun 2016 12:38:21 +0000 (14:38 +0200)]
tests: Test partial commits for local remotes

This was broken before, fixed in the previous commit.

Closes: #324
Approved by: yuqi-zhang

9 years agopull: Write commitpartial files for local imports too
Colin Walters [Tue, 7 Jun 2016 13:50:58 +0000 (09:50 -0400)]
pull: Write commitpartial files for local imports too

Just like HTTP fetches, these can be interrupted, so we need to write
the commitpartial files.

Closes: #324
Approved by: yuqi-zhang

9 years agorefs: resolve conflict between local/remote repos
Yu Qi Zhang [Thu, 23 Jun 2016 16:11:50 +0000 (16:11 +0000)]
refs: resolve conflict between local/remote repos

Add the functionality to use the same name for refs in local and remote
repos. This helps users keep track of local refs of remote origin, much
like local and remote git branches.

Previously, when a local ref is specified, resolve_refspec would fall
back to searching through remote repos if the ref is not found locally.
This function now takes an extra flag to specify whether it should
search through remote repos. Additionally, ostree_repo_resove_rev_ext
was added to call resolve_refspec with fallback_remote being false, so
refs --create would no longer complain when trying to create a local
ref of the same name as a remote one.

Fix remote repo parsing not being handled correctly on refs --create.

Closes: #363
Approved by: jlebon

9 years agopull: Correctly handle repo->parent_repo when applying static deltas
Alexander Larsson [Thu, 23 Jun 2016 09:51:15 +0000 (11:51 +0200)]
pull: Correctly handle repo->parent_repo when applying static deltas

In flatpak i was using a parent repo, and it failed to update
with ENOENT when dispatching an set-read-source opcode, because the
object it referenced was in the parent repo.

This fixes that by making _ostree_repo_read_bare_fd look
at parent_repo.

Closes: #362
Approved by: cgwalters

9 years agorefs: Fix a logic error
Mathnerd314 [Sat, 18 Jun 2016 17:06:31 +0000 (11:06 -0600)]
refs: Fix a logic error

I encountered the Opening remotes/ dir error with some broken pull code, and this fixes it.

Closes: #358
Approved by: cgwalters

9 years agocore: Add OSTREE_OBJECT_TYPE_COMMIT_META
Mathnerd314 [Thu, 16 Jun 2016 05:37:29 +0000 (23:37 -0600)]
core: Add OSTREE_OBJECT_TYPE_COMMIT_META

This is cleaner than the loose_path_with_suffix approach

Closes: #359
Approved by: cgwalters

9 years agoconfigure: Turn on -Wempty-body
Mathnerd314 [Thu, 16 Jun 2016 19:59:06 +0000 (13:59 -0600)]
configure: Turn on -Wempty-body

I spent half an hour debugging an extra semicolon,
and this C "feature" is not used at all in ostree

Closes: #359
Approved by: cgwalters

9 years agocore: Use OSTREE_SHA256_STRING_LEN instead of 64
Mathnerd314 [Sat, 18 Jun 2016 16:31:19 +0000 (10:31 -0600)]
core: Use OSTREE_SHA256_STRING_LEN instead of 64

Closes: #359
Approved by: cgwalters

9 years agocore: Fix wrong return value docs
Krzesimir Nowak [Wed, 22 Jun 2016 09:16:21 +0000 (11:16 +0200)]
core: Fix wrong return value docs

ostree_commit_get_parent() returns a string form of a checksum, not a
binary form.

Closes: #360
Approved by: cgwalters

9 years agorefs: allow overwrite of empty folders
Yu Qi Zhang [Mon, 20 Jun 2016 20:20:58 +0000 (20:20 +0000)]
refs: allow overwrite of empty folders

We noticed that once a ref folder is created, there is no existing
command that can remove it. For example, once "foo/bar" is created,
even if the user deletes foo or all the refs under foo, the folder
will persist.

Now when the user attempts to create a ref "foo" either through commit
or refs --create, if a folder "foo" exists but is empty of refs, the
folder is removed and the new ref "foo" is created.

New unit tests in tests-ref.sh verify this functionality.

Closes: #354
Approved by: cgwalters

9 years agolibglnx porting: Drop uses of gs_file_openat_noatime
Colin Walters [Wed, 15 Jun 2016 01:55:40 +0000 (21:55 -0400)]
libglnx porting: Drop uses of gs_file_openat_noatime

We're not really doing the "noatime" thing anymore.

Closes: #341
Approved by: jlebon

9 years agolib: Use g_file_enumerator_iterate() if available, with fallback
Colin Walters [Wed, 15 Jun 2016 01:51:10 +0000 (21:51 -0400)]
lib: Use g_file_enumerator_iterate() if available, with fallback

Import `gs_file_enumerator_iterate()` for the next six months or
so...after RHEL 7.3 is released I'm strongly considering hard
requiring 2.46 or so.

Likely at some point we should figure out how to share more "glib
backport" code with NetworkManager at least.

Closes: #341
Approved by: jlebon

9 years agolib: Use sd_journal directly (optionally)
Colin Walters [Tue, 14 Jun 2016 17:12:21 +0000 (13:12 -0400)]
lib: Use sd_journal directly (optionally)

This was the last caller of libgsystem that isn't
`gs_file_get_path_cached()`.  I think the use case ostree has where
the same code can be called via command line and via a shared library
*and* via a daemon is rather unusual, so let's just copy the code for
logging from libgsystem into here.

For example rpm-ostree hard depends on a daemon mode, so it'll just
use `sd_journal` directly.

Closes: #341
Approved by: jlebon

9 years agolibglnx porting: Use of GSDirFdIterator
Colin Walters [Tue, 14 Jun 2016 14:46:15 +0000 (10:46 -0400)]
libglnx porting: Use of GSDirFdIterator

This one was pretty simple.  One of the uses in `repo.c` was just a
leftover variable.

Closes: #341
Approved by: jlebon

9 years agolibostree.sym: Fix test-symbols
Colin Walters [Mon, 20 Jun 2016 22:13:58 +0000 (18:13 -0400)]
libostree.sym: Fix test-symbols

The test isn't smart enough to ignore comments, so change the prefix.

Closes: #356
Approved by: jlebon

9 years agoRelease 2016.6
Colin Walters [Mon, 20 Jun 2016 14:46:50 +0000 (10:46 -0400)]
Release 2016.6

9 years agopull: Ensure we always process queue only from main thread
Colin Walters [Fri, 17 Jun 2016 02:16:27 +0000 (22:16 -0400)]
pull: Ensure we always process queue only from main thread

I was easily reproducing a hang on pulls with thousands of requests on
current git master.  The initial symptom seemed to be that there are
multiple code paths where we don't invoke
`session_thread_process_pending_queue()`.  We really need to do
that any time we remove something from the outstanding queue,
to ensure it gets filled again.

A further issue is that we were tying the lifecycle of the pending
object to the `GTask`, but the task could be unref'd from the main
thread (via a `GSource` on the main thread), and that introduced
threadsafety issues, because the hash table and other data suddenly
could be concurrently modified.

Both of these need to be fixed together.  First, we introduce
`Arc<Pending>`, and ensure that both the main and worker threads hold
references.

Second, we ensure that we re-process the queue *immediately* whenever
a task is done, inside the worker thread, rather than doing it
incidentally via an unref.  This architecture is quite similar to what
the outside pull code is doing.

Closes: #350
Approved by: jlebon

9 years agotests: Support OT_SKIP_READDIR_RAND
Colin Walters [Fri, 17 Jun 2016 13:43:51 +0000 (09:43 -0400)]
tests: Support OT_SKIP_READDIR_RAND

For some reason I'm really not inclined to debug right now, `libtool`
is eating the `-fsanitize=address` argument when linking
`libreaddir-rand.so`, which causes failures since we're trying to
`LD_PRELOAD`.

Closes: #351
Approved by: jlebon

9 years agobuild: Fix libreaddir-rand to honor global CFLAGS
Colin Walters [Fri, 17 Jun 2016 13:36:51 +0000 (09:36 -0400)]
build: Fix libreaddir-rand to honor global CFLAGS

It's unfortunate that in automake one has to explicitly include the globa
`$(AM_CFLAGS)` if one sets `CFLAGS`, and similarly for other variables.

I'm trying to use `-fsanitize=address`, and not including it was
causing linker failures.

We also weren't inheriting the global warnings etc., so I had to fix a
decl-after-statement.

Closes: #351
Approved by: jlebon

9 years agomanual: Discuss mirroring
Colin Walters [Thu, 16 Jun 2016 15:25:37 +0000 (11:25 -0400)]
manual: Discuss mirroring

This should likely be its own section, but it makes enough sense here
for now too.

Closes: #347
Approved by: yuqi-zhang

9 years agorepo: Avoid a possible divide by zero in progress
Colin Walters [Fri, 17 Jun 2016 01:51:13 +0000 (21:51 -0400)]
repo: Avoid a possible divide by zero in progress

The previous code was subject to a divide by zero if less than a
second had passed.  Rework it so we only do the divide if more than a
second has passed.

Closes: #349
Approved by: Mathnerd314

9 years agolibglnx porting: delete temp files on failure of file creation
Yu Qi Zhang [Thu, 16 Jun 2016 18:51:10 +0000 (18:51 +0000)]
libglnx porting: delete temp files on failure of file creation

We noticed the temp files being left over in ostree when (mistakenly)
trying to create refs with names in use by folders. This fix removes
temp files created by glnx_file_replace_contents_at on failure.

Closes: #348
Approved by: cgwalters

9 years agoAdd "archive" as an alias for "archive-z2"
Colin Walters [Thu, 16 Jun 2016 14:07:26 +0000 (10:07 -0400)]
Add "archive" as an alias for "archive-z2"

I find the "-z2" is really a long ago relic of the past when I changed
the format.  We no longer have anything to do with the original
`archive`, so let's start allowing people to type `--mode=archive`
which just looks saner.

At some point later I'll update the docs too, but it'll be an annoying
transition period as we'll have to say "On older OSTree, use -z2" etc.

Closes: #346
Approved by: giuseppe

9 years agoChangelog for previous commit
Simon McVittie [Thu, 16 Jun 2016 12:19:01 +0000 (08:19 -0400)]
Changelog for previous commit

9 years agofix debian/watch
Jeremy Bicha [Thu, 16 Jun 2016 06:59:45 +0000 (02:59 -0400)]
fix debian/watch

9 years agomanual: Link to mender.io
Colin Walters [Wed, 15 Jun 2016 13:20:11 +0000 (09:20 -0400)]
manual: Link to mender.io

Came out of a discussion on the list.

Closes: #344
Approved by: jlebon

9 years agorefs: add "ostree refs --create" and unit tests
Yu Qi Zhang [Tue, 14 Jun 2016 14:13:06 +0000 (14:13 +0000)]
refs: add "ostree refs --create" and unit tests

Added the ability to create a ref (much like a git tag) for an
existing commit through "ostree refs EXISTING --create=NEWREF".
Previously the only way to create a new ref was by creating a new commit,
but refs --create allows multiple refs to point to the same commit.

The command will fail if:
 - None/more than one existing ref is specified
 - The specified EXISTING tag does not exist, or was not specified
 - The specified NEWREF already exists, or is the name of a folder

Add unit tests in tests-ref.sh to verify above functionality

Closes: #340
Approved by: jlebon

9 years agoApply patches from upstream to make ostree buildable on Debian jessie
Simon McVittie [Wed, 15 Jun 2016 18:20:04 +0000 (14:20 -0400)]
Apply patches from upstream to make ostree buildable on Debian jessie

9 years ago2016.5-4
Simon McVittie [Tue, 14 Jun 2016 19:35:49 +0000 (15:35 -0400)]
2016.5-4

9 years agoAdd another bug reference
Simon McVittie [Tue, 14 Jun 2016 19:32:19 +0000 (15:32 -0400)]
Add another bug reference

9 years agoAdd a patch to link libreaddir-rand to libdl
Simon McVittie [Tue, 14 Jun 2016 19:29:18 +0000 (15:29 -0400)]
Add a patch to link libreaddir-rand to libdl

This should fix test failures on Ubuntu (Closes: #826857)

9 years agoMark some patches as merged upstream
Simon McVittie [Tue, 14 Jun 2016 19:26:49 +0000 (15:26 -0400)]
Mark some patches as merged upstream

9 years agolib: Port some manual close() cleanups to be glnx_fd_close
Colin Walters [Thu, 9 Jun 2016 18:30:14 +0000 (14:30 -0400)]
lib: Port some manual close() cleanups to be glnx_fd_close

Just noticed this while reading some code, we didn't have many manual
`out: close()` bits left, this pushes us over the edge to autocleanup
almost everywhere.

Closes: #332
Approved by: jlebon

9 years agobuild: re-create tests/ostree-symlink-stamp if Makefile changes
Simon McVittie [Sun, 12 Jun 2016 13:32:51 +0000 (09:32 -0400)]
build: re-create tests/ostree-symlink-stamp if Makefile changes

The filename of the real ostree executable could be either .libs/ostree
or .libs/lt-ostree.

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #337
Approved by: cgwalters

9 years agolibostreetest: include libtest.sh from srcdir, not builddir
Simon McVittie [Sun, 12 Jun 2016 13:21:19 +0000 (09:21 -0400)]
libostreetest: include libtest.sh from srcdir, not builddir

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #337
Approved by: cgwalters

9 years agolibtest: make gpghome in tmpdir writeable
Simon McVittie [Sun, 12 Jun 2016 09:51:11 +0000 (10:51 +0100)]
libtest: make gpghome in tmpdir writeable

Otherwise, during "make distcheck" it will be read-only (because it
is a copy of the read-only ${srcdir} with permissions preserved), and
deletion will fail during cleanup.

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #337
Approved by: cgwalters

9 years agobuild: distribute more test files
Simon McVittie [Sun, 12 Jun 2016 09:45:48 +0000 (10:45 +0100)]
build: distribute more test files

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #337
Approved by: cgwalters

9 years agobuild: distribute TAP helper scripts in tarballs
Simon McVittie [Sun, 12 Jun 2016 09:43:34 +0000 (10:43 +0100)]
build: distribute TAP helper scripts in tarballs

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #337
Approved by: cgwalters

9 years agobuild: distribute test scripts in tarballs
Simon McVittie [Sun, 12 Jun 2016 09:39:46 +0000 (10:39 +0100)]
build: distribute test scripts in tarballs

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #337
Approved by: cgwalters

9 years agobuild: distribute libostree.sym in tarballs
Simon McVittie [Sun, 12 Jun 2016 09:36:44 +0000 (10:36 +0100)]
build: distribute libostree.sym in tarballs

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #337
Approved by: cgwalters

9 years agoautogen.sh: rely on VPATH for submodules' Makefile-*.am.inc
Simon McVittie [Sun, 12 Jun 2016 09:31:29 +0000 (10:31 +0100)]
autogen.sh: rely on VPATH for submodules' Makefile-*.am.inc

This avoids hard-coding the autogen-time ${srcdir} into our build
system, and might fix "make distcheck".

We don't need to specify ${srcdir} explicitly in the various variables,
because Automake always uses make's VPATH feature to look in both
${builddir} and ${srcdir} at build time.

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #337
Approved by: cgwalters

9 years agoLink libreaddir-rand to libdl
Simon McVittie [Sun, 12 Jun 2016 14:25:21 +0000 (10:25 -0400)]
Link libreaddir-rand to libdl

It uses dlsym(). There's no point in being extra-portable here
because OSTree only targets Linux anyway.

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #336
Approved by: cgwalters

9 years agoIf build-time tests fail, try 4 more times
Simon McVittie [Sun, 12 Jun 2016 13:50:51 +0000 (09:50 -0400)]
If build-time tests fail, try 4 more times

To get an idea of whether the failure is reproducible.

9 years agodebian/test.sh: factor out our dh_auto_test wrapper
Simon McVittie [Sun, 12 Jun 2016 13:49:25 +0000 (09:49 -0400)]
debian/test.sh: factor out our dh_auto_test wrapper

Clean up any stray processes even if the test fails.

Signed-off-by: Simon McVittie <smcv@debian.org>
9 years agoBuild-depend on procps, used to check for leaked processes
Simon McVittie [Sun, 12 Jun 2016 13:45:52 +0000 (09:45 -0400)]
Build-depend on procps, used to check for leaked processes